package com.autumn.platform.core.accessor;

import java.util.Map;

import com.autumn.platform.core.Defaults;

public class DataAccessors {

    private static IDataAccessorFactory getFactory() {
        return Defaults.getDefaultComponent(IDataAccessorFactory.class);
    }

    public static IDataAccessor newDataAccessor() {
        return getFactory().newDataAccessor();
    }

    public static IDataAccessor newDataAccessor(Object root) {
        return getFactory().newDataAccessor(root);
    }

    public static IDataAccessor newDataAccessor(Object root, Map<String, Object> vars) {
        return getFactory().newDataAccessor(root, vars);
    }
}
